package com.xhtt.modules.cfg.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.xhtt.modules.cfg.entity.CfgHoseInfo;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 软管库 Mapper 接口
 * </p>
 *
 * @author feipc
 * @since 2019-02-20
 */
public interface CfgHoseInfoMapper extends BaseMapper<CfgHoseInfo> {

    List<CfgHoseInfo> queryPage(Page<CfgHoseInfo> page, @Param(value = "ps") Map<String, Object> params);

    void updateUsed(@Param(value = "upHoseIds") List<Integer> upHoseIds);

    List<CfgHoseInfo> validList(@Param(value = "productId") Integer productId, @Param(value = "pressureLevel") String pressureLevel);

    void updateCurProduct(@Param(value = "upHoseIds") List<Integer> upHoseIds, @Param(value = "productId") Integer productId, @Param(value = "productName") String productName);

    void flushProduct(@Param(value = "hoseIdList") List<Integer> hoseIdList);
}
